package com.fishsticks.model;

import com.fishsticks.R;
import com.fishsticks.view.ToDoListActivity;

import android.app.AlertDialog;
import android.app.Dialog;
import android.content.Context;
import android.content.DialogInterface;
import android.widget.Button;
import android.widget.Spinner;
import android.widget.Toast;
import android.view.LayoutInflater;
import android.view.View;
import android.view.View.OnClickListener;
import android.view.ViewGroup;

public class FilterDialog extends AlertDialog.Builder {
	
	private Spinner filterOptionsSpinner;

	/**
	 * Creates a custom filter dialog box with the 
	 * default "dark theme" if one isn't provided
	 * 
	 * @param context The application context
	 */
	public FilterDialog(Context context) {
		super(context, 0);
	}
	
	
	/**
	 * Creates a custom filter dialog box with the 
	 * provided "theme" reference ID number
	 * 
	 * @param context The application context
	 * @param theme The ID number of the theme in AlertDialog.Builder
	 */
	public FilterDialog(Context context, int theme) {
		super(context, theme);
		
		this.setTitle("Filter");
		
		this.setPositiveButton("Filter", new DialogInterface.OnClickListener() {
			@Override
			public void onClick(DialogInterface dialog, int which) {
				Toast.makeText(getContext(), "Searching...", Toast.LENGTH_SHORT).show();
			}
		});
    	
    	this.setNegativeButton("Cancel", new DialogInterface.OnClickListener() {
			@Override
			public void onClick(DialogInterface dialog, int which) {
				dialog.dismiss();
			}
		});
	}
	
	
	public void initMainFilterDialog() {
		//LayoutInflater inflater = (LayoutInflater) getContext().getSystemService(Context.LAYOUT_INFLATER_SERVICE);
    	//View filterDialogView = inflater.inflate(R.layout.main_filter_dialog, (ViewGroup) findViewById(R.id.search_dialog_box_root));
    	
    	//Spinner mainSpinner = (Spinner) filterDialogView.findViewById(R.id.filterSpinnerMainFilterPage);
    	
    	//this.setView(filterDialogView);

	}
	
}
